<#macro copyright>
/**
<#nested>
 * @author ${author!'Administrator'}
 * @since ${.now?date}
 */
</#macro>

##定义宏，查询所有列
<#macro allColumn>
<#list table.columns as column>
        ${column.columnName}<#if column_has_next>,</#if>
</#list>
</#macro>

##定义宏，查询所有列
<#macro conditionByColumns columns=table.columns>
        <#list columns as column>
            <if test="t.${column.name} != null<#if column.javaType == 'String'> and t.${column.name} != ''</#if>">
                and ${column.columnName} = ${r"#"}{t.${column.name}}
            </if>
        </#list>
</#macro>


##定义宏，动态修改数据
<#macro dynamicUpdateCondition columns=table.columns>
        <set>
        <#list columns as column><#if column_index != 0>
            <if test="t.${column.name} != null">
                ${column.columnName}=${r"#"}{t.${column.name}},
            </if>
        </#if></#list>
        </set>
</#macro>